<nz-table #ajaxTable nzShowSizeChanger [nzFrontPagination]="false" [nzData]="dataSet" [nzLoading]="loading" [nzTotal]="total"
  [(nzPageIndex)]="pageIndex" [(nzPageSize)]="pageSize" (nzPageIndexChange)="searchData()" (nzPageSizeChange)="searchData(true)">
  <thead (nzSortChange)="sort($event)" nzSingleSort>
    <tr>
      <th nzShowSort nzSortKey="name">Name</th>
      <th nzShowSort>NickName</th>
      <th nzShowSort nzSortKey="email"><span>Email</span></th>
      <th nzShowSort nzSortKey="email"><span>Gender</span></th>
      <th nzShowSort nzSortKey="email"><span>Signature</span></th>
      <th nzShowSort nzSortKey="email"><span>Status</span></th>
      <th nzShowSort nzSortKey="email"><span>LastLoginTime</span></th>
      <th nzShowSort nzSortKey="email"><span>Action</span></th>
    </tr>
  </thead>
  <tbody>
    <tr *ngFor="let data of ajaxTable.data">
      <td>{{data.username}}</td>
      <td>{{data.nickname}}</td>
      <td>{{data.email}}</td>
      <td>{{data.gender | genderRePipe}}</td>
      <td>{{data.signature}}</td>
      <td><span class="{{data.userStatus == 'ACTIVE' ? 'userActive' : 'userDisable'}}">{{data.userStatus | userStatusPipe}}</span></td>
      <td>{{data.lastSignInTime | date:'yyyy-MM-dd hh:mm:SS '}}</td>
      <td><button nz-button nzType="{{data.userStatus == 'ACTIVE' ? 'danger' : 'primary'}}" nzGhost (click)="userStatusClick(data.id)">{{data.userStatus == 'ACTIVE' ? 'Disable' : 'Active'}}</button></td>
    </tr>
  </tbody>
</nz-table>
